2004-10-30 Matthias Clasen <mclasen@redhat.com>
+ * tests/testtext.c: Add a "Select All" menuitem. (#156792,
+ Paolo Borelli)
+
* gtk/gtkicontheme.c (insert_theme): Sort the dir_mtimes
list in the same way as the search path.
(theme_subdir_load): Avoid stat()ing subdirs if the theme
2004-10-30 Matthias Clasen <mclasen@redhat.com>
+ * tests/testtext.c: Add a "Select All" menuitem. (#156792,
+ Paolo Borelli)
+
* gtk/gtkicontheme.c (insert_theme): Sort the dir_mtimes
list in the same way as the search path.
(theme_subdir_load): Avoid stat()ing subdirs if the theme
2004-10-30 Matthias Clasen <mclasen@redhat.com>
+ * tests/testtext.c: Add a "Select All" menuitem. (#156792,
+ Paolo Borelli)
+
* gtk/gtkicontheme.c (insert_theme): Sort the dir_mtimes
list in the same way as the search path.
(theme_subdir_load): Avoid stat()ing subdirs if the theme
2004-10-30 Matthias Clasen <mclasen@redhat.com>
+ * tests/testtext.c: Add a "Select All" menuitem. (#156792,
+ Paolo Borelli)
+
* gtk/gtkicontheme.c (insert_theme): Sort the dir_mtimes
list in the same way as the search path.
(theme_subdir_load): Avoid stat()ing subdirs if the theme
gtk_widget_show_all (dialog);
}
+static void
+do_select_all (gpointer callback_data,
+ guint callback_action,
+ GtkWidget *widget)
+{
+ View *view = view_from_widget (widget);
+ GtkTextBuffer *buffer;
+ GtkTextIter start, end;
+
+ buffer = view->buffer->buffer;
+
+ gtk_text_buffer_get_bounds (buffer, &start, &end);
+ gtk_text_buffer_select_range (buffer, &start, &end);
+}
+
typedef struct
{
/* position is in coordinate system of text_view_move_child */
{ "/_Edit", NULL, 0, 0, "<Branch>" },
{ "/Edit/Find...", NULL, do_search, 0, NULL },
+ { "/Edit/Select All", "<control>A", do_select_all, 0, NULL },
{ "/_Settings", NULL, NULL, 0, "<Branch>" },
{ "/Settings/Wrap _Off", NULL, do_wrap_changed, GTK_WRAP_NONE, "<RadioItem>" },